import { Entity, PrimaryGeneratedColumn, Column, CreateDateColumn } from 'typeorm';

@Entity('recommendations')
export class Recommendation {
  @PrimaryGeneratedColumn()
  recommend_id!: number;

  @Column({ length: 255 })
  title!: string;

  @Column({ type: 'text', nullable: true })
  content?: string;

  @Column({ length: 255, nullable: true })
  image_url?: string;

  @Column({ length: 255, nullable: true })
  link?: string;

  @Column({ default: 0 })
  priority!: number;

  @CreateDateColumn()
  created_at!: Date;

  @Column({ type: 'datetime', nullable: true })
  updated_at?: Date;

  @Column({ type: 'tinyint', default: 1 })
  status!: number;
} 